#include "stdafx.h"
#include "func.hpp"
bool GetUserFolder(IN wchar_t *env_name, OUT wchar_t *m_path, IN int path_len)
{
	if(env_name == NULL || m_path == NULL ) return false;
	wchar_t *pvulnhunt = L"\\Vulnhunt\\ActiveXF";

	wchar_t * appdata = _wgetenv(env_name);
	if(appdata == NULL) return false;
	if (wcslen(appdata)+wcslen(pvulnhunt) > path_len)
	{
		return false;
	}
	swprintf(m_path, L"%s%s", appdata, pvulnhunt);
	return true;
}